﻿namespace SampleApplication.CoffeeShopSample.Implementation.Domain
{
    #region Usings

    using Dependencies.Domain;
    using System;
    using System.Globalization;

    #endregion Usings

    public class PlasticCup : ICup
    {
        public PlasticCup(IBeverage beverage)
        {
            if (beverage == null) throw new ArgumentNullException("beverage");

            Beverage = beverage;
        }

        /// <summary>
        /// Returns a string that represents the current object.
        /// </summary>
        /// <returns>
        /// A string that represents the current object.
        /// </returns>
        public override string ToString()
        {
            return string.Format(CultureInfo.CurrentCulture, "Plastic Cup containing {0}", Beverage.Name);
        }

        public IBeverage Beverage { get; private set; }
    }
}